/**
 * webpack配置文件 - 生产环境
 * @module webpack
 * @author zhanghuan
 * @date 2021/03/10
 */
const path = require('path')
const { CleanWebpackPlugin } = require('clean-webpack-plugin')
const webpackCommon = require('./webpack.common')

process.env.NODE_ENV = 'production'

module.exports = {
    ...webpackCommon,
    plugins: [
        new CleanWebpackPlugin(),
        ...webpackCommon.plugins
    ],
    output: {
        path: path.resolve(__dirname, 'dist'),
        filename: 'bundle.js'
    }
};